//@表示src
//import是es6的模块语法，表示引入模块
import http from '@/http/http';

const url = "menus"

export default {
  getListByPage: function (data, params) {
    return http.post(`${url}/list.do`, data, {
      params
    });
  },
  del: function (id) {
    return http.get(`${url}/del.do`, {
      params: {
        id
      }
    });
  },
  delBatch: function (ids) {
    return http.get(`${url}/delBatch.do`, {
      params: {
        ids
      }
    });
  },
  save: function (data) {
    return http.post(`${url}/save.do`, data);
  },
  edit: function (id) {
    return http.get(`${url}/edit.do`, {
      params: {
        id
      }
    });
  },

  findAll: function () {
    return http.get(`${url}/findAll.do`);
  }
};
